package com.transaction.factory;


import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Service;

import java.util.Map;

@Component
public class MyFactory {

    @Autowired
    private Map<String, Factory> map;

    public Factory getFactory(String type) {
        return map.get(type);
    }
}
